package com.example.ssm.dao;

import com.example.ssm.dto.PageInfoMy;
import com.example.ssm.entity.Address;
import com.example.ssm.vo.AddressAndUserVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author: dang
 * @Description: TODO
 * @Date: 2023/12/5 18:28 星期二
 */
public interface IAddress {

    int add(Address address);
    void edit(Address address);
    void del(Integer id);
    List<Address> search(Address address);


    int addBatch(@Param("addressList") List<Address> addressList);
    int delBatch(List<Integer> integers);
//address的一对一联查第一种方式
    AddressAndUserVO getAddressAndUser(Integer id);

//address的一对一联查
    AddressAndUserVO getAddressAndUserOne(@Param("id") Integer id);
//分页查询
    List<Address> getPage(@Param("pageInfo") PageInfoMy pageInfo);


}
